System and Method for Implementing SSD-Based I/O Caches

ABSTRACT

A method for caching a data block stored on a first storage device and onto a second storage device including determining whether a data block being requested contains a first type of data, upon a condition in which the data block contains the first type of data, writing the data block to the second storage device and upon a condition in which the data block does not contain the first type of data, determining whether a correspondingly mapped block on the second storage device contains the first type of data, and only writing the data block to the second storage device upon a condition in which the correspondingly mapped block does not contain the first type of data.

FIELD OF THE INVENTION

The invention relates to the field methods and systems for improving theinput/output performance of data storage systems, and more particularlyto implementations of solid-state drive based caches for improving theinput/output performance of data storage systems.

BACKGROUND OF THE INVENTION

The use of current generation NAND-Flash solid state drives (SSDs) foraccelerating demanding server workloads, such as file and mail servers,business and scientific data analysis, as well as for online transactionprocessing databases is becoming more common as the advantages broughtforth by their cost and performance characteristics over those oftypical hard-disk drives (HDDs) are brought to fruition. Table 1, showsthe difference in performance metrics of HDDs versus SSDs:

TABLE I HDD AND SSD PERFORMANCE METRICS. SSD HDD Price/capacity ($/GB)$3 $0.3 Response time (ms) 0.17 12.6 Throughput (R/W) (MB/s) 277/202100/90  IOPS (R/W) 30,000/3,500  150/150

SSDs have the potential to mitigate input/output (I/O) penalties byoffering superior performance to HDDs, albeit at a higher cost pergigabyte (GB). In addition, SSDs bear complexity caveats, related totheir internal organization and operational properties. Accordingly,mixed-device system architectures are currently preferred in datastorage systems. In one example, a mixed-device system includes SSDs asa caching layer on top of HDDs, where the cost of the SSDs is expectedto be amortized over increased I/O performance, both in terms ofthroughput and access rate.

Recently, prior art implementations of SSDs as a caching layer on top ofHDDs have focused on how to improve the I/O performance using SSDcaches, including, for example the following publications.

T. Kgil and T. Mudge, “FlashCache: a NAND flash memory file cache forlow power web servers,” in CASES '06. ACM, pp. 103-112 discloses the useof flash memory as a secondary file cache for web servers.

S.-W. Lee, B. Moon, C. Park, J.-M. Kim, and S.-W. Kim, “A case for flashmemory ssd in enterprise database applications,” in SIGMOD '08. ACM, pp.1075-1086 discloses an analysis of the impact of using SSDs intransaction processing.

X. Ouyang, S. Marcarelli, and D. K. Panda, “Enhancing CheckpointPerformance with Staging IO and SSD,” in IEEE SNAPI '10, pp. 13-20discloses how SSDs may be used in efficient checkpointing.

H. J. Lee, K. H. Lee, and S. H. Noh, “Augmenting RAID with an SSD forenergy relief,” in HotPower '08. USENIXAssociation, pp. 12-12 discloseshow SSDs can be used as a large cache on top of a RAID arrangement toconserve energy.

One of the problems with these prior art approaches is that they areapplication-specific and require application knowledge, intervention andtuning. In addition, the I/O bottlenecks resulting from the interfaceand relationship between SSDs and HDDs in such mixed-device systems areproblematic when attempting to implement a general solution. This hasdriven the application-specific solutions currently known in the priorart. Accordingly, there is a need in the prior art for improvements tocache systems that address one or more of the above-identified problemswith the prior art.

SUMMARY OF THE INVENTION

It is an object of the invention to address one or more of theabove-identified problems with the prior art with respect to cachingdata stored on HDDs onto SSDs, however, the invention may also beapplied to other types of data stores, and preferably to other types ofdata stores where the comparative performance metrics of the data storesare relatively comparable to each other in an analogous manner as wasdescribed above in the comparison between HDDs and SSDs. In any event,some advantages of the invention may be applicable to all cachingmethods and systems.

According to one embodiment of the invention, there is provided a methodfor carrying out a cache write operation of a data block stored on afirst storage device and cached onto a second storage device. The methodincludes the steps of (a) mapping blocks of the first storage deviceonto blocks of the second storage device; (b) intercepting a request forthe data block stored on the first storage device; (c) determiningwhether the data block being requested contains filesystem metadata; (d)upon a condition in which the data block contains filesystem metadata,writing the data block to the second storage device; (e) upon acondition in which the data block does not contain filesystem metadata,determining whether a correspondingly mapped block on the second storagedevice contains filesystem metadata; (f) upon a condition in which thecorrespondingly mapped block contains filesystem metadata aborting thecache write operation; (g) upon a condition in which the correspondinglymapped block does not contain filesystem metadata, determining whetherthe correspondingly mapped block contains data that is more frequentlyaccessed than data on the data block; (h) upon a condition in which thecorrespondingly mapped block contains data that is more frequentlyaccessed than data on the data block, aborting the cache writeoperation; and, (i) upon a condition in which the correspondingly mappedblock contains data that is less frequently accessed than data on thedata block, writing the data on the data block to the correspondinglymapped block on the second storage device.

According to one aspect of the invention, the first storage device is ahard disk drive, and in another aspect, the second storage device is asolid state drive.

According to another aspect of this embodiment, the intercepting step iscarried out in an input/output path between the first storage device anda filesystem accessing the first storage device. Preferably, theintercepting step is carried by an admission control module implementedas a virtual block layer between the filesystem and the first storagedevice.

According to another embodiment of the invention, there is provided amethod for caching a data block stored on a first storage device andonto a second storage device; the method including the steps of (a)mapping blocks of the first storage device onto blocks of the secondstorage device; (b) intercepting a request for the data block stored onthe first storage device; (c) determining whether the data block beingrequested contains a first type of data; (d) upon a condition in whichthe data block contains the first type of data, writing the data blockto the second storage device; (e) upon a condition in which the datablock does not contain the first type of data, determining whether acorrespondingly mapped block on the second storage device contains thefirst type of data; (f) upon a condition in which the correspondinglymapped block contains the first type of data aborting the cache writeoperation; and, (g) upon a condition in which the correspondingly mappedblock does not contain the first type of data, writing the data on thedata block to the correspondingly mapped block on the second storagedevice. For greater clarity, the steps identified in the method are ofthis embodiment are not limited to being in the order specified. Forexample, the mapping step may be repeated at any point during the methodto optimize performance or reallocate data caching locations.

According to an aspect of this second embodiment, the method furtherincludes, prior to writing the data, the steps of (h) determiningwhether the correspondingly mapped block contains a second type of data;(i) upon a condition in which the correspondingly mapped block containsthe second type of data, aborting the cache write operation; (j) upon acondition in which the correspondingly mapped block does not contain thesecond type of data executing the writing the data on the data block tothe correspondingly mapped block on the second storage device.

According to another aspect of this second embodiment, the first type ofdata is filesystem metadata.

According to another aspect of this second embodiment, the second typeof data is data that is more frequently accessed than data on the datablock.

According to another aspect of this second embodiment, the first storagedevice is a hard disk drive.

According to another aspect of this second embodiment, the secondstorage device is a solid state drive.

According to another aspect of this second embodiment, the interceptingstep is carried out in an input/output path between the first storagedevice and a filesystem accessing the first storage device.

According to another aspect of this second embodiment, the interceptingstep is carried by an admission control module implemented as a virtualblock layer between the filesystem and the first storage device.

According to a third embodiment of the invention, there is provided anon-transitory computer readable medium having computer readableinstructions thereon to carry out the method as herein described.

According to a fourth embodiment of the invention, there is provided acomputer system including a filesystem in communication with a firststorage device via an input/output path; an admission control module inthe input/output path, and a second storage device in communication withthe admission control module. The admission control module includesinstructions for (a) mapping blocks of the first storage device ontoblocks of the second storage device; (b) intercepting a request for adata block stored on the first storage device; (c) determining whetherthe data block being requested contains a first type of data; (d) upon acondition in which the data block contains the first type of data,writing the data block to the second storage device; (e) upon acondition in which the data block does not contain the first type ofdata, determining whether a correspondingly mapped block on the secondstorage device contains the first type of data; (f) upon a condition inwhich the correspondingly mapped block contains the first type of dataaborting the cache write operation; and, (g) upon a condition in whichthe correspondingly mapped block does not contain the first type ofdata, writing the data on the data block to the correspondingly mappedblock on the second storage device.

According to an aspect of this fourth embodiment, the admission controlmodule further includes instructions for, prior to the writing the datastep of (h) determining whether the correspondingly mapped blockcontains a second type of data; (i) upon a condition in which thecorrespondingly mapped block contains the second type of data, abortingthe cache write operation; and, (j) upon a condition in which thecorrespondingly mapped block does not contain the second type of dataexecuting the writing the data on the data block to the correspondinglymapped block on the second storage device.

According to another aspect of the fourth embodiment, the first type ofdata is filesystem metadata.

According to another aspect of the fourth embodiment, the second type ofdata is data that is more frequently accessed than data on the datablock.

According to another aspect of the fourth embodiment, the first storagedevice is a hard disk drive.

According to another aspect of the fourth embodiment, the second storagedevice is a solid state drive.

BRIEF DESCRIPTION OF THE FIGURES

FIG. 1 shows a general computer system on which embodiments of theinvention may be implemented.

FIG. 2 shows one example of a system architecture for implementing anembodiment of the invention.

FIG. 3 is a flowchart showing the read/write process flow according tothe invention.

FIG. 4 is a flowchart showing details of the write process flowaccording to the invention.

FIGS. 5( a)-(c) show the impact of a block selection scheme on TPC-H forboth direct-mapped and fully-set-associative caches.

FIGS. 6( a)-(c) show the SPECsfs2008 results of the impact of filesystemmetadata on performance.

FIGS. 7( a)-(c) show the impact of different associativities and cachesizes on TPC-H performance.

FIGS. 8( a)-(c) show the impact on associativity and write policy onSPECsfs2008 performance with a 128 GB cache size.

FIGS. 9( a)-(c) show the impact on associativity and write policy onSPECsfs2008 performance with a 64 GB cache size.

DETAILED DESCRIPTION

The invention provides for a system and method by which second types ofstorage devices, for example SSDs, can be used as caches in the I/O pathof, preferably, mixed-device arrangements including at least one SSD andat least one first type of storage device, such as HDDs. The embodimentsas described below discuss the implementation of SSDs and HDDs inparticular, as these are the preferred implementations of the invention,however, the invention is not to be considered as limited to same. Inits implementation as will be described hereinbelow, the inventiontransparently and dynamically places data blocks in the SSD cache assuch data blocks flow in the I/O path between the main memory of acomputer system and the HDDs associated therewith. For the purposes ofthis disclosure, it will be understood that references to an SSD and/oran HDD in the singular apply equally to references to same in theplural, and vice versa, in the sense that SSD and HDD storage mediumsmay be connected in serial or parallel to increase the storage capacityor device performance required. The invention is not to be considered aslimited by either the singular or plural of HDD and SDD unlessexplicitly stated.

The various embodiments of the invention may be implemented in a generalcomputer system, or in a network of computer systems comprising two ormore general computer systems. The invention generally operates withinthe context of a computer system, and serves to provide an improvementto the data storage capabilities available to general known computersystems, an exemplary one of which is shown in FIG. 1. As shown, thecomputer system 20 has a number of physical and logical components,including a central processing unit (“CPU”) 24, random access memory(“RAM”) 28, an input/output (“I/O”) interface 32, a network interface36, non-volatile storage 40, and a local bus 44 enabling the CPU 24 tocommunicate with the other components. The CPU 24 executes an operatingsystem and a number of software systems. RAM 28 providesrelatively-responsive volatile storage to the CPU 24. The I/O interface32 allows for input to be received from one or more devices, such as akeyboard, a mouse, etc., and outputs information to output devices, suchas a display and/or speakers. The network interface 36 permitscommunication with other systems. Non-volatile storage 40 stores theoperating system and programs. During operation of the computer system20, the operating system, the programs, and the data may be retrievedfrom the non-volatile storage 40 and placed in RAM 28 to facilitateexecution. It is in the I/O connection between the non-volatile storage40 and the RAM 28 that the invention is generally applied. The generalcomputer system is shown for illustrative purposes only, and it will beunderstood that the invention may equally be applied to any computersystem that has non-volatile storage in communication with a memory suchas RAM, where there is a desire to cache certain data for carrying outfaster read/write operations

In implementing the invention to be transparent and dynamic such thatapplication-specific adaptations are generally not required, a number ofimprovements are made over the prior that result from an identificationof various problems that applicant has identified to be relevant inimplementing the invention. First, based on their expected importance tosystem performance, the invention uses a two-level block selectionscheme and dynamically differentiates between first and second types ofHDD blocks before admitting them into the SSD Cache. More specifically,blocks that contain filesystem metadata are distinguished from blocksthat contain application data. This is of importance in that variousfilesystem studies have shown that metadata handling is important toapplication performance. In addition, recent trends have shown that theimpact of filesystem metadata accesses has become more pronounced asmore complex applications and computer systems are used. Secondly, forall HDD blocks, the invention proposes maintaining a running estimate ofthe number of accesses over a sliding time window. This information isthen used to prevent infrequently accessed blocks from evicting morefrequently accessed ones. The implementations described below do notrequire application instrumentation or static a-priori workloadanalysis.

Next, a manner for representing the state of the SSD cache blocks inmemory, such as DRAM is required. As will be described below,implementation of the invention results in metadata size growingproportionally to the SSD capacity available. Accordingly, compactingmetadata to fit in DRAM is an important aspect. The metadata footprintin DRAM will increase with SSD device capacity, thereby makinghigh-associativity organizations less cost effective. As is known, thereare two aspects of cache design that determine the DRAM required formetadata: cache-associativity and cache line size. The inventionproposes without being limited to two alternatives forcache-associativity: (a) a direct-mapped organization, which minimizesthe required amount of DRAM for metadata, and (b) a fullyset-associative organization that allows more informed block replacementdecisions at the cost of consuming more DRAM space for its metadata. Inaddition, the performance impact from increasing the cache line size isanalyzed, although larger cache lines decrease the required metadataspace in DRAM, and doing so causes performance degradation in manycases.

Write-handling policies are also explored in terms of write-through vs.write-back which affects both system performance and reliability,write-invalidation vs. write-update in case of cache write hits, andwrite-allocation for cache write misses. It will be shown below that thechoice of the write policy can make a significant difference inperformance.

Maintaining a high degree of concurrent I/O accesses is important andconsidered in this invention. Any cache design needs to allow multiplepending I/O requests to be in progress at any time. The inventionproperly handles hit-under-miss and out-of-order completions by trackingthe dependencies between in-flight I/O requests. The implementationsdescribed below minimize the overhead of accessing an additional staterequired for this purpose, as this additional state is required for allI/O operations that pass through the cache. The data structure used tocarry this out is also compacted so that it fits within the limited DRAMspace.

Although SSD caches bear similarities to traditional DRAM-based caches,there are significant differences as well, which result in theimplementations of the invention as herein described. First, the impactof the block mapping policy, e.g. direct-mapped vs.fully-set-associative, is not as clear as in DRAM caches. In addition,SSD caches are significantly larger, resulting in a considerably largermetadata footprint. This is a factor unique to SSDs, considering theirincreasing size. Finally, unlike DRAM caches, SSD caches can be madepersistent, thus avoiding warm-up overheads.

Referring now to FIG. 2, there is shown a system architecture in whichthe use of SSDs as I/O caches according to one embodiment of theinvention is shown. The invention provides for a virtual block deviceabstraction layer 210, referred to as the virtual block layer 210,arranged to intercept requests in the I/O path and transparently cachingHDD blocks 215 to dedicated SSD partitions 220 via the SSD cache layer225. An admission control module 230 controls the caching of HDD blocksas described below. The address space of the SSDs is not visible tohigher system layers, such as filesystems 235 and databases 240 at theapplication level. The virtual block layer 210 is preferably placed inthe I/O path below the system buffer cache 235. Thus, all decisions oncache read/write operations are made dynamically as data is beingretrieved from or written to the HDD, and in isolation from applicationsand/or filesystems.

Referring now to FIG. 3, there is shown a representative depiction ofhow I/O requests are handled according to the invention. Each HDD blockis preferably mapped 305 to an SSD cache block, according to cacheassociativity for example. The mapping step may be repeated duringexecution of the method, and may further account for the type of data ina block being intercepted as well the blocks stored in the SSD. Forreads, the invention checks if the cached block is valid at 310 and ifso, forwards the request to the SSD (read hit) at 315. Otherwise, datais fetched from the HDD (read miss) at 320 and an asynchronous SSD writeI/O (cache fill) is scheduled at 325.

For write operations, both hits and misses, the invention implements butis not limited to a write-through mechanism that has several advantagesover prior art solutions that have been proposed in alternateimplementations, including eliminating the need for synchronous metadataupdates that have severe implications for latency-sensitive workloads,and in addition improving upon write-back cache designs that reducesystem resilience to failures that would result in a loss of data if anSSD drive were to fail. The write-through arrangement provides writepolicies for forwarding the write request either to both the HDD and theSSD (write-hdd-sdd), or only to the HDD. In the second policy, during awrite hit, the invention can either update (write-hdd-upd) or invalidate(write-hdd-inv) the corresponding cache block. The choice of writepolicy has implications for write-intensive workloads, as will be shownbelow. These operations and decisions described above may be implementedby the admission control module 230 shown in FIG. 2.

The admission control module 230 differentiates HDD blocks based ontheir expected importance to system performance. For this purpose, theinvention implements a two-level block selection scheme that controlswhether or not a specific cache block should be admitted to the SSDcache, according to its importance. Importance may be derived, in part,by differentiating between two classes of HDD blocks, namely filesystemmetadata and filesystem data blocks. Other ways of deriving importanceor differentiating between classes are also contemplated by theinvention and can be implemented into the admission control module.

Filesystem metadata I/Os are preferably given priority over regular dataI/Os for two reasons. First, metadata operations represent a largepercentage of all the requests in a typical system. Hence, their impacton performance is disproportionate. Next, there has been a markedincrease in filesystem capacities in recent years, with the average filesize remaining relatively small. This results in more files and, thus,more metadata. The filesystem metadata footprint is further increased bythe need for checksums at the filesystem level to achieve higher dataprotection, an approach already adopted by state-of-the-art filesystems.Therefore, it is increasingly difficult to rely solely on DRAM formetadata caching.

The Admission Control Module

The admission control module provides for differentiation betweenfilesystem metadata and filesystem, for example, by modifying the XFS(in Linux kernel implementations) filesystem to tag metadata requests bysetting a dedicated bit in the I/O request descriptor or by using anadditional interceptor and tagging module below the filesystem asdiscussed in [0093]. Next, this information is used at the block levelto categorize each HDD block. This modification does not affectfilesystem performance and can easily be implemented in otherfilesystems as well. It is also noted that this modification onlyrequires an additional class bit per SSD cache block.

Next, for the second level of the selection scheme, not all data blocksare treated equally. For example, in database environments indicesimprove query performance, by allowing fast access to specific recordsaccording to search criteria. Index requests produce frequent,small-size, and random HDD accesses, a pattern that stresses HDDperformance. Moreover, given a set of queries to a database, the datatables are not usually access with the same intensity. In web-serverenvironments, web pages usually exhibit temporal locality. Thus, it isexpected that less benefit is derived from caching web pages that haverecently been accessed only sporadically. Finally, the same principleapplies to mail-servers in that more recent emails are more likely to beaccessed again sooner than older ones. Based on these observations, datablocks on SSDs are cached by differentiating them according to theiraccess frequency.

At the second level of selection, a running estimate of the accesses toeach HDD block is kept in memory such that the one with the higheraccess count is more likely to remain in the SSD cache. Thisdifferentiation of HDD blocks overrides the selection of the “victimblock” for eviction as determined by the least recently used (LRU)replacement policy in the fully-set-associative cache. Althoughworkloads like TPC-C tend to have repetitive references, a good matchfor LRU, other workloads, such as TPC-H, rely on extensive one-timesequential scans which fill-up the cache with blocks that are notexpected to be reused any time soon. Such blocks evict others that maybe accessed again soon. If the LRU replacement is allowed to evictblocks indiscriminately, the cache will not be effective until it isre-populated with the more commonly used blocks. This is also themotivation behind adaptive replacement cache (ARC) policy, which keepstrack of both frequently used and recently used pages and continuouslyadapts to the prevailing pattern in the reference stream. In the currentinvention, these per-block reference counters form an array in DRAMindexed by the HDD block number. The DRAM required for these countersincreases in this invention along with the file-set size, not with theunderlying HDD space. The evaluation presented below shows that thismemory space is worth the trade-off, since differentiation improvesperformance overall.

Referring now to FIG. 4, there is shown the flowchart of part of themethod implemented by the admission control module. Of note, the controlpath of read hits and writes to the HDD remains unaffected. On the otherhand, cache fills and write hits to the SSD cache pass though theadmission control module (as was graphically depicted in FIG. 2), whichdecides whether the write operation should actually be performed or not.The method implemented includes the steps of determining if an incomingrequest is a metadata request 410, and if so, it is immediately writtento the cache at step 420 since filesystem metadata I/Os are prioritizedover regular data I/Os. Otherwise, the incoming request containsfilesystem data and the admission control module checks at step 430whether the corresponding cache block contains filesystem metadata. Thecorresponding block is determined by the cache mapping and/orreplacement policies or variations. For instance, in a direct-mappedcache the mapping policy will uniquely specify the corresponding block.In a fully set associative cache that uses an LRU replacement policy,the LRU policy will determine the corresponding block. Variations ofmapping functions and replacement policies are possible and are notlimited or excluded by the invention. If so, the cache fill is abortedat step 440. If not, both the incoming and the existing cache blockcontains regular data. In this case, step 450 is carried out todetermine which block accessed more times, and the cache fill isperformed or aborted such that the block that is accessed more times iswritten to or maintained in the cache.

Decisions that are typically taken in a cache for various operations arewell known, but in particular, the invention focuses on policies relatedto when data read or written from the disk device is or is not writtento the cache, and proposes, for example, using the type of the data thatare both part of the request and the cache block to decide on whether toallocate such data to the cache or not. The decision on whether thecache will use a write-back or write-through is provided herein by wayof example only. A specific two-level selection scheme proposed by thisinvention relies on taking into account for admission by the admissioncontrol module into the cache, information on whether the blockrequested and the corresponding block in the cache contains data ormetadata and the frequency counter of each block. Additional classes ofblocks defined by other metrics and criteria as well as steps forprioritizing these classes and weighting them are also contemplated bythe invention. For example, distinctions can be made in the particulartype of data, such as system versus data files, by way of a non-limitingexample. Furthermore, selection can be made based on file parametersother than the frequency of access including, but not limited to, filesize, date of last access, file extension, etc.

Cache Associativity

The choice of associativity is mainly a tradeoff between performance andmetadata footprint. Traditionally, DRAM caches use afully-set-associative policy since their small size requires reducingcapacity conflicts. SSD caches, however, are significantly larger and,thus, they may use a simpler mapping policy, without significantlyincreasing capacity conflicts. In implementing the invention, twoalternatives for cache associativity are considered. In particular, (a)a direct-mapped, and (b) a fully-set-associative cache design. On theone hand, a direct-mapped cache requires less metadata, hence a lowermemory footprint, compared to a fully-set associative cache. This isvery important, since metadata are required for representing the stateof the SSD blocks in DRAM, and DRAM space is limited. Furthermore, thedirect mapped cache design does not impose mapping overheads on thecritical path and is fairly simple to implement.

All these advantages are particularly important when consideringoffloading caching to storage controllers. However, modern filesystemsemploy elaborate space allocation techniques for various purposes. Forinstance, XFS tends to spread out space allocation over the entire freespace in order to enable utilization of all the disks backing thefilesystem. Such techniques result in unnecessary conflict misses due todata placement. On the other hand, a fully-set-associative cacherequires a significantly larger metadata footprint to allow a moreelaborate block replacement decision through the LRU replacement policy.However, such a design fully resolves the data placement issue, thusreducing conflict misses. Metadata requirements for this design include,apart from the tag and the valid/dirty bits, pointers to the next andprevious elements of the LRU list, as well as additional pointers foranother data structure, explained below.

Designing a fully-set-associative cache appears to be deceptivelysimple. However, experience shows that implementing such a cache is farfrom trivial and it requires dealing with the following two challenges.First, it requires an efficient mechanism that quickly determines thestate of a cache block, without increasing latency in the I/O path. Thisis necessary since it is impossible to check all cache blocks inparallel for a specific tag, as a hardware implementation would do. Theinvention uses but is not limited to arranging cache blocks into a hashtable-like data structure. For each HDD block processed, a bucket isselected by hashing the HDD block number using a version of the RobertJenkins' 32-bit integer hash function that has been modified to suitethe goals of the invention. The list of cache blocks is then traversed,looking for a match. This arrangement minimizes the number of cacheblocks that must be examined for each incoming I/O request. Second,there is a large variety of replacement algorithms typically used in CPUand DRAM caches, as well as in some SSD buffer management schemes, allof them prohibitively expensive for SSD caches in terms of metadatasize. Moreover, some of these algorithms assume knowledge of the I/Opatterns the workload exhibits, whereas the invention as implementedaims to be transparent to the application level. It has beenexperimentally found that simpler replacement algorithms, such as randomreplacement, result in unpredictable performance. According, applicanthas opted for the LRU policy, since it provides a reasonable referencepoint for other more sophisticated policies, and the two-level selectionscheme can be designed as a complement to the LRU replacement decision.

Cache Line Size

Metadata requirements for both cache associativities can be reduced byusing larger cache lines. This is a result of reducing the need ofper-block tag, as many blocks are now represented with the same tag. Bydoing so, metadata footprint can be reduced by up to 1.9 times and 6.9times, for the direct-mapped and the fully-set-associative cache,respectively. In addition, larger cache lines can benefit workloads thatexhibit good spatial locality while smaller cache lines benefit morerandom workloads. A less obvious implication is that larger cache linesalso benefit the flash translation layers (FTL) of SSDs. A large numberof small data requests can quickly overwhelm most FTLs, since finding arelatively empty page to write to is becoming increasingly difficult.Finally, using larger cache lines has latency implications, as discussedlater.

I/O Concurrency

Modern storage systems exhibit a high degree of I/O concurrency, havingmultiple outstanding I/O requests. This allows overlapping I/O withcomputation, effectively hiding the I/O latency. To sustain a highdegree of asynchrony, the invention provides for callback handlersinstead of blocking, waiting for I/O completion. In addition, concurrentaccesses are permitted on the same cache line by using a form ofreader-writer locks, similar to the buffer-cache mechanism. Since usinga lock for each cache line prohibitively increases metadata memoryfootprint, only pending I/O requests are tracked. Caching HDD blocks toSSDs has another implication for I/O response time: Read misses incur anadditional write I/O to the SSD when performing a cache fill. Once themissing cache line is read from the HDD into DRAM, the buffers of theinitial request are filled and the admission control module can performthe cache fill by either (a) re-using the initial application I/Obuffers for the write I/O, or (b) by creating a new request and copyingthe filled buffers from the initial request. Although the first approachis simpler to implement, it increases the effective I/O latency becausethe issuer must wait for the SSD write to complete. On the other hand,the second approach completely removes the overhead of the additionalcache fill I/O, as the initial request is completed after the buffercopy and then the cache fill write request is asynchronously issued tothe SSD. However, this introduces a memory copy in the I/O path, andrequires maintaining state for each pending cache write. Preferably, thesecond approach is adopted as the memory throughput in the architectureof the invention is an order of magnitude higher than the sustained I/Othroughput. However, other SSD caching implementations, such as instorage controllers, may decide differently, based on their availablehardware resources.

Handling write misses is complicated in the case of larger cache lineswhen only part of the cache line is modified: the missing part of thecache line must first be read from the HDD in memory, merged with thenew part, and then written to the SSD. It has been found that thisapproach disproportionally increases the write miss latency withoutproviding significant hit ratio benefits. Therefore, support is providedfor partially valid cache lines by maintaining valid and dirty bits foreach block inside the cache line. For write requests forwarded to bothHDDs and SSDs, the issuer is notified of completion when the HDDs finishwith the I/O. Although this increases latency, it may be unavoidablesince write-through implementations of the invention start with a coldcache in case of failures and the up-to-date blocks must always belocated on the HDDs, to protect against data corruption.

Performance Evaluation Methodology

The preferred embodiments of the invention herein described wereevaluated on a server-type x86-based system, equipped with a Tyan S5397motherboard, two quadcore Intel Xeon 5400 64-bit processors running at 2GHz, 32 GB of DDR-II DRAM, twelve 500-GB Western DigitalWD5001AALS-00L3B2 SATA-II disks connected on an Areca ARC-1680D-IX-12SAS/SATA storage controller, and four 32-GB enterprise-grade Intel X25-E(SLC NAND Flash), connected on the motherboard's SATA-II controller. TheOS installed is CentOS 5.5, with the 64-bit 2.6.18-194.32.1.e15 kernelversion. The storage controller's cache is set to writethrough mode.Both HDDs and SSDs are arranged in RAID-0 configurations, the firstusing the Areca hardware RAID, and the latter using the MD Linux driverwith a chunk-size of 64 KB. The XFS filesystem with a block-size of 4KB, mounted using the inode64, nobarrier options was used. Moreover, theSSD device controller implements in firmware a significant portion ofthe functionality of these filesystems. The database server used isMySQL 5.0.77.

The evaluation is focused on I/O-bound operating conditions, where theI/O system has to sustain high request rates. In some cases, we limitthe available DRAM memory, in order to put more pressure on the I/Osubsystem. For our evaluation, we use three I/O-intensive benchmarks:TPC-H, SPECsfs2008, and Hammerora, the parameters of which are discussednext.

TPC-H: is a data-warehousing benchmark that issues business analyticsqueries to a database with sales information. We execute queries Q1 toQ12, Q14 to Q16, Q19, and Q22 back to back and in this order. We use a28 GB database, of which 13 GB are data files, and vary the size of theSSD cache to hold 100% (28 GB), 50% (14 GB), and 25% (7 GB) of thedatabase, respectively. TPC-H does a negligible amount of writes, mostlyconsisting of updates to file-access timestamps. Thus, the choice of thewrite policy is not important for TPC-H, considering we start executionof the queries with a cold cache. We set the DRAM size to 4 GB, andexamine how the SSD cache size affects performance.

SPECsfs2008 emulates the operation of an NFSv3/CIFS file server; ourexperiments use the CIFS protocol. In SPECsfs2008, a set of increasingperformance targets is set, each one expressed in CIFSoperations-per-second. The file set size is proportional to theperformance target (120 MB per operation/sec). SPECsfs2008 reports thenumber of CIFS operations-per-second actually achieved, as well asaverage response time per operation. For our experiments, we set thefirst performance target at 500 CIFS ops/sec, and then increase the loadup to 15,000 CIFS ops/sec. The DRAM size is set to 32 GB. Contrary toTPC-H, SPECsfs2008 produces a significant amount of write requests, sowe examine, along with associativity, the impact of the write policy onperformance. We use two cache sizes, of 64 and 32 GB, respectively.

TPC-C is an OLTP benchmark, simulating order processing for a wholesaleparts supplier and its customers. This workload issues a mix of severalconcurrent short transactions, both read-only and update-intensive. Theperformance number reported by this benchmark is New Order TransactionsPer Minute (NOTPM). We use the Hammerora load generator on a 155-GBdatabase that corresponds to a TPC-C configuration with 3,000warehouses. We run experiments with 512 virtual users, each executing1,000 transactions. As with TPC-H, we limit system memory to 4 GB.

Performance Results

In this section we first examine how the Two-Level Block SelectionMechanism (2LBS) improves the performance of the SSD cache asimplemented by the invention. Then, we analyze how four designparameters: 1) cache associativity, 2) cache size 3) write policy, and4) cache line size affect the performance of the system hereindescribed.

Block Selection Scheme

For this case study we select cases that exhibit a fair amount ofconflict misses, since that is when we expect our two-level blockselection scheme to benefit performance. Thus, we do not explore trivialcases, such as having the whole workload fitting in the SSD cache, forwhich no additional performance benefit can be acquired. We analyze howeach level of our proposed scheme separately improves performance, aswell as the additional performance gains by combining them. We comparethe performance of an SSD cache that uses the block selection schemewith: i) native HDDs runs, and ii) an LRU base cache. The base cachedoes not use neither levels of the 2LBS scheme and employs thewrite-hdd-upd write policy. For the two designs (2LBS and base), weanalyze the performance of both the direct-mapped and LRU-basedfully-set-associative caches.

1) TPC-H: Since this benchmark performs a negligible amount of writes.both the file-set size and the number of files do not grow duringworkload execution. Thus, applicant's system receives a minimal amountof filesystem metadata I/Os. Consequently, pinning filesystem metadataon the SSD cache provides no performance benefit for workloads likeTPC-H.

FIGS. 5( a)-(c) show the results of using the 2LBS scheme for TPC-H. Inall these experiments, the system starts with a cold cache, using 4 GBof DRAM. Since TPC-H is very sensitive to DRAM, for the 2LBS scheme weallocate extra DRAM, as much as required. We use the medium size (14 GB)direct-mapped (DM) and fully-set-associative (FA) caches as a test case.As shown in FIG. 5( a) the use of the block selection mechanism improvesthe performance of the direct-mapped and the fully-set-associativecaches by approximately 1.95 times and 1.53 times, respectively. Alsonoteworthy is the fact that the medium size (14 GB) direct-mapped 2LBScache performs better than the large size (28 GB) base cachecounterpart. This is because the medium-size 2LBS design caches moreimportant data than the large size cache, for a lower hit ratio (FIG. 5(b)), and for 1.9% less disk utilization (FIG. 5( c)). However, the samebehavior is not reproduced for the fully-set-associative cache, sincethis cache design employs the LRU replacement policy, which providesbetter performance for the larger cache.

2) SPECsfs2008: Contrary to TPC-H, SPECsfs2008 equally accessesfilesystem data blocks and thus, using running estimates of blocksaccesses cannot further improve performance. On the other hand, thefile-set produced by SPECsfs2008 continuously increases during workloadexecution and thus, the metadata footprint continuously increases aswell. Consequently, it is assumed that system performance is affected bythe filesystem metadata DRAM hit ratio. To validate this assumption, werun SPECsfs2008 on the native 12 HDDs setup, while varying the availableDRAM size. FIG. 6( a) shows that, as the DRAM size increases, the numberof metadata I/Os that reach the admission control module significantlydecreases, providing substantial performance gains. This is evident whenmoving from 4 GB to 8 GB of DRAM; a 186% reduction in metadata requestsresults in 71% better performance. Thus, we expect to gain significantperformance improvements for SPECsfs2008 by pinning filesystem metadataon SSDs.

For our experiments, we choose the worst-case scenario with 4 GB DRAM,using the best write policy (write-hdd-upd), and starting with an 128 GBcold cache. Since SPECsfs2008 is less sensitive to DRAM for filesystemdata caching, we do not allocate further memory for the 2LBS scheme.FIG. 6( b) shows that even the base version of the inventionsignificantly improves performance, achieving an increase in speed of1.71 times and 1.85 times for the direct-mapped andfully-set-associative caches, respectively. Furthermore, by pinningfilesystem metadata on SSDs, performance further improves by 16% and 7%for the two associativities, respectively. These improvements areaccompanied by a significant decrease in latency. FIG. 6( c) shows thatthe admission control module supports roughly 3,000 more operations persecond for the same latency, compared to the native 12 HDDs run. Inaddition, there is a 21% and 26% decrease in latency for thedirect-mapped and fully-set-associative cache designs, respectively,when comparing the base with the 2LBS version of the invention at thelast sustainable target load (7000 ops/sec). This, however, is not aresult of an increase in hit ratio (not shown), but only of pinningfilesystem metadata on SSDs.

3) Hammerora: Finally, we examine how the two-level block selectionarrangement performs when faced with a blackbox workload. For thispurpose, we use Hammerora, 4 GB of DRAM, and a cold cache, large enoughto hold half the TPC-C database (77.5 GB). Since Hammerora is an OLTPworkload, we expect the admission control module to receive asignificant amount of write requests, hence we choose our best writepolicy (write-hdd-upd) for these experiments. The results show that eventhe base version of the invention improves performance by 20% and 55%,for the direct-mapped and fully-set-associative cache designs,respectively. In addition, with the 2LBS arrangement, performancefurther improves by 31% and 34% for the two associativities,respectively. Not both levels of the 2LBS scheme equally benefitHammerora. When the two levels are applied individually on thefully-set-associative cache, there is 9% and 24% performance improvementrespectively, compared to the base version. As with SPECsfs2008,although there is no change in the hit ratio between the base and the2LBS versions for both associativities, the performance benefits are aresult of which HDD blocks are cached. For this workload, diskutilization is at least 97%, while cache utilization remains under 7%for all configurations. These results reveal that SSD caches accordingto the invention can greatly improve OLTP workloads, especially when alarge percentage of the database fits in the cache.

System Design Parameters

Next, an analysis is provided as to how cache associativity, cache size,and the write policy affect the performance of the invention. Then, wepresent observations on using larger cache lines. These experiments areperformed without the 2LBS scheme, so that the impact of theseparameters becomes more evident.

1) TPC-H: FIGS. 7( a)-(c) show the performance gains of the invention,compared to the native HDDs. In all experiments, the system of theinvention starts with a cold cache and uses 4 GB of DRAM. FIG. 7( a)shows that performance improves along with larger cache sizes, both forthe direct-mapped and the fully-set-associative cache.

Cache associativity greatly affects performance as well; when theworkload does not fit entirely in the SSD cache, a medium size (14 GB)fully-set-associative cache performs better than all of thedirect-mapped counterparts (7, 14, and 28 GB), by giving anapproximately 2.71 times, 2.16 times and 1.33 times higher performance,respectively. Generally, the fully-set-associative cache performs betterdue to higher hit ratio, shown in FIG. 7( b). This is because thefully-set-associative cache has significantly less conflict misses thatthe direct mapped counter-part, due to the spread-out mapping the latterexhibits. This benefit, however, diminishes as the cache size decreases,evident by the fact that for the smallest cache size (7 GB) the twoassociativities perform roughly equally. In this case, the 3.54%difference at hit ratio results in 3% better performance, because thesignificantly increased number of conflict misses has absorbed a largepercentage of potential benefits from using an SSD cache. Furthermore,FIG. 7( c) shows that even a small decrease in HDD utilization resultsin significant performance benefits. For instance, thefully-set-associative medium size cache (14 GB) has 11.89% less HDDutilization than the small size (7 GB) counterpart, resulting in a 4.23times better speedup. Generally, HDD utilization is reduced, as thepercentage of workload that fits in the cache increases. SSD utilizationremains under 7% in all configurations. Moreover, the native SSD runachieves a 38.81 times speedup, compared to HDDs.

Finally, TPC-H is very sensitive to the DRAM size. Performance isexponentially improved, as the percentage of the workload that fits inDRAM is increased. For instance, in case the whole workload fits inDRAM, the achieved speedup is 168.8 times. By combining all the aboveobservations, we conclude that the choice of a proper DRAM size alongwith enough SSD space can lead to optimal performance gains for archivaldatabase benchmarks, such as TPC-H.

2) SPECsfs2008: For this workload we compare the performance of theinvention with the native 12 HDD run, using 32 GB DRAM, and performingall experiments starting with a cold cache. We expect the choice ofwrite policy to significantly affect performance, since this workloadproduces a fair amount of write requests. Furthermore, since SPECsfs2008produces a very large number of small files during its execution, weexpect the effect of the spread-out mapping the direct-mapped cacheexhibits to be more evident in this workload. FIG. 8( a) presents theresults using 128 GB of SSD cache. It is noted that depending on thewrite policy chosen, the increase in speed gained by the inventionvaries from 11% to 33% and from 10% to 63%, for the direct-mapped andfully-set-associative cache designs, respectively. The performance gainsare directly dependent on the hit ratio, shown in FIG. 8( b), achievedby each write policy. The write-hdd-ssd write policy achieves the lowesthit ratio, hence the lowest performance improvement. This is becauseSPECsfs2008 produces a huge file-set but only access 30% of it. Thus,useful data blocks are evicted, overwritten by blocks that are never beread. Furthermore, because SPECsfs2008 exhibits a modify-read accesspattern, the write-hdd-upd write policy exhibits better hit ratio thanwritehdd-inv, since the first will update the corresponding blockspresent in the SSD cache, while the latter will essentially evict them.

Cache associativity also affects performance: the best write policy(write-hdd-upd) for the fully-set-associative cache performs 25% betterthan its direct-mapped counterpart, a result of the increased hit ratio.FIG. 8( c) shows that the response time per operation also improves withhigher hit ratios: the better the hit ratio, the longer it takes for thestorage system to get overwhelmed and, thus, it can satisfy greatertarget loads. Furthermore, CPU utilization (not shown) always remainsbelow 25%, showing that the small random writes that SPECsfs2008exhibits make HDDs the main performance bottleneck. HDD utilization isalways 100%, while cache utilization remains below 25% for allconfigurations. Based on these observations, we conclude that even forwrite-intensive benchmarks, such as SPECsfs2008, that produce huge filesets the addition of SSDs as HDD caches in accordance with the inventionholds great performance potential.

Finally, we examine how reducing the cache size affects performance. Werun again our experiments, this time using 64 GB of SSD cache. We noticethat, although the behavior of the write-policies remain the same (FIG.9( a)), The system of the invention now becomes saturated earlier in theexecution of the workload. This is due to the increased latencies (FIG.9( c)) observed, and the fact that the hit ratio (FIG. 9( b)) starts todrop in earlier target loads. Still, there is a 22% and 38% performanceimprovement, compared to the native HDD run, for the direct-mapped andthe fully-set-associative caches, respectively.

3) Impact of Cache Line Size on Performance: The I/O workloads generallyexhibit poor spatial locality, hence cache lines larger than one block(4 KB) result in lower hit ratio. Thus, the benefits described above arenot enough to amortize the impact on performance of this lost hit ratio,hence performance always degrades. However, since larger cache lines mayeventually compensate the lost performance in the long term due tobetter interaction with the SSD's metadata management techniques intheir flash translation layers (FTL).

Further Discussion

The DRAM space required by embodiments of the invention in each case areshown in Table II.

TABLE II TRADING OFF DRAM SPACE FOR PERFORMANCE IN Azor. TPC-HSPECsfs2008 Hammerora Base Cache 1.28 (DM)/6.03 (FSA) Metadata FootprintMB/GB of SSD Base Cache Max. 14.02× 63% 55% Performance Gain AdditionalTotal 28 MB No overhead 56 MB Metadata for 2 LBS Max. Performance 95%(DM) 16% (DM) 34% (FSA) Gain with 2 LBS

The base cache design is the LRU-based fully-set associative cache. The2LBS scheme offers additional gains to the base cache, and the bestassociativity in this case is shown in parenthesis. We see that, at thecost of consuming a considerable amount of DRAM in some cases, theinvention provides significant performance improvement. Furthermore, theDRAM space required scales with the size of the SSD cache size, not withthe capacity of the underlying HDDs. Thus, we expect the DRAM spacerequirements for metadata to remain moderate. However, if DRAMrequirements are an issue for some systems, modifications to theinvention can be made to trade DRAM space with performance, by usinglarger cache lines as earlier described.

Finally, the cost/benefit trade-off between DRAM size and SSD capacity,only affects workloads sensitive to DRAM, such as TPC-H. On thecontrary, for workloads like TPC-C, additional DRAM has less impact aswe observed in experiments not reported here. The experiments show thatDRAM hit ratio remains below 4.7%, even if DRAM size is quadrupled to 16GB. Similarly, for SPECsfs2008, additional DRAM serves only to improvethe hit ratio for filesystem metadata.

The invention's 2LBS arrangement is feasible within disk controllers byembedding a metadata flag within the network storage protocol (e.g.SCSI) command packets transmitted from storage initiators to storagetargets. Storage protocols have unused fields/commands that can carrythis information. Then, it will be implemented in the storage controller(target in a networked environment) by using per-block access counters.The main issue in this case is standardization of storage protocols, andwhether it makes sense to push hints from higher layers to lower. Asshown, there is merit to such an approach.

Applying the invention to other filesystems requires modifying thefilesystem implementation. We have modified XFS to mark metadataelements. However, transparent detection of metadata is needed is somesetups, e.g. in virtual machines where the hypervisor cannot have accessto block identity information. A mechanism has also been developed forautomatically detecting filesystem metadata without any modifications tothe filesystem itself, using the metadata magic numbers for thispurpose. Preliminary results with the benchmarks used in this inventionshow that this mechanism adds low overheads to the common I/O path.

The invention makes extensive use of metadata to keep track of blockplacement. The system, like most traditional block-level systems, doesnot update metadata in the common I/O path, thus avoiding the necessaryadditional synchronous I/O. Accordingly there is no guarantee ofmetadata consistency after a failure: in this case the invention startswith a cold cache. This is possible because of the write-through policyensuring that all data has its latest copy in the HDD. If the SSD cachehas to survive failures, this would require trading-off higherperformance with consistency to execute the required synchronous I/O inthe common path. However, it is preferably to choose to optimize thecommon path at the expense of starting with a cold cache after afailure.

Given that SSD controllers currently do not expose any block stateinformation, we rely on the flash translation layer (FTL) implementationwithin the SSD for wear-leveling. Designing block-level drivers andfile-systems in a manner cooperative to SSD FTLs which improveswear-leveling and reduces FTL overhead is an important direction,especially while raw access to SSDs is not provided by vendors to systemsoftware.

Various modifications to the invention are contemplated withoutdeparting from the spirit and scope of the invention which is defined inthe claims that follow. While various steps and computer components havebeen herein used, these are to be given their ordinary definition aswould be known in the art, unless explicitly limited or otherwise hereindefined. The above-described embodiments are intended to be examples ofthe present invention and alterations and modifications may be effectedthereto, by those of skill in the art, without departing from the scopeof the invention that is defined solely by the claims appended hereto.

1. A method for carrying out a cache write operation of a data blockstored on a first storage device and cached onto a second storagedevice; the method comprising: (a) mapping blocks of said first storagedevice onto blocks of said second storage device; (b) intercepting arequest for said data block stored on said first storage device; (c)determining whether said data block being requested contains filesystemmetadata; (d) upon a condition in which said data block containsfilesystem metadata, writing said data block to said second storagedevice; (e) upon a condition in which said data block does not containfilesystem metadata, determining whether a correspondingly mapped blockon said second storage device contains filesystem metadata; (f) upon acondition in which said correspondingly mapped block contains filesystemmetadata aborting the cache write operation; (g) upon a condition inwhich said correspondingly mapped block does not contain filesystemmetadata, determining whether said correspondingly mapped block containsdata that is more frequently accessed than data on said data block; (h)upon a condition in which said correspondingly mapped block containsdata that is more frequently accessed than data on said data block,aborting the cache write operation; (i) upon a condition in which saidcorrespondingly mapped block contains data that is less frequentlyaccessed than data on said data block, writing said data on said datablock to said correspondingly mapped block on said second storagedevice.
 2. A method according to claim 1, wherein said first storagedevice is a hard disk drive.
 3. A method according to claim 2, whereinsaid second storage device is a solid state drive.
 4. A method accordingto claim 1, wherein said intercepting step is carried out in aninput/output path between said first storage device and a filesystemaccessing said first storage device.
 5. A method according to claim 4,wherein said intercepting step is carried by an admission control moduleimplemented as a virtual block layer between said filesystem and saidfirst storage device.
 6. A method for caching a data block stored on afirst storage device and onto a second storage device; the methodcomprising: (a) mapping blocks of said first storage device onto blocksof said second storage device; (b) intercepting a request for said datablock stored on said first storage device; (c) determining whether saiddata block being requested contains a first type of data; (d) upon acondition in which said data block contains said first type of data,writing said data block to said second storage device; (e) upon acondition in which said data block does not contain said first type ofdata, determining whether a correspondingly mapped block on said secondstorage device contains said first type of data; (f) upon a condition inwhich said correspondingly mapped block contains said first type of dataaborting the cache write operation; and, (g) upon a condition in whichsaid correspondingly mapped block does not contain said first type ofdata, writing said data on said data block to said correspondinglymapped block on said second storage device.
 7. A method according toclaim 6, wherein said step (g) further comprises, prior to said writingsaid data, the steps of: (h) determining whether said correspondinglymapped block contains a second type of data; (i) upon a condition inwhich said correspondingly mapped block contains said second type ofdata, aborting the cache write operation; and, (j) upon a condition inwhich said correspondingly mapped block does not contain said secondtype of data executing said writing said data on said data block to saidcorrespondingly mapped block on said second storage device.
 8. A methodaccording to claim 6, wherein said first type of data is filesystemmetadata.
 9. A method according to claim 7, wherein said second type ofdata is data that is more frequently accessed than data on said datablock.
 10. A method according to claim 6, wherein said first storagedevice is a hard disk drive.
 11. A method according to claim 7, whereinsaid second storage device is a solid state drive.
 12. A methodaccording to claim 6, wherein said intercepting step is carried out inan input/output path between said first storage device and a filesystemaccessing said first storage device.
 13. A method according to claim 12,wherein said intercepting step is carried by an admission control moduleimplemented as a virtual block layer between said filesystem and saidfirst storage device.
 14. A method according to claim 6, furthercomprising an additional mapping step following one or more of steps (b)to (g); wherein said additional mapping step overrides the mappingcarried out in step (a).
 15. A method according to claim 14, whereinsaid additional mapping step considers one or more of a type of dataintercepted in said intercepting step and a type of data stored in saidsecond storage device.
 16. A method according to claim 6, wherein saiddetermining step comprises reading stored values indicative of saidfirst type of data from the filesystem or from a repository of saidstored values.
 17. A method according to claim 6, wherein saiddetermining step is executed in real-time by an admission controlmodule.
 18. A non-transitory computer readable medium having computerreadable instructions thereon to carry out the method of claim
 6. 19. Acomputer system comprising a filesystem in communication with a firststorage device via an input/output path; an admission control module insaid input/output path; a second storage device in communication withsaid admission control module; wherein said admission control moduleincludes instructions for (a) mapping blocks of said first storagedevice onto blocks of said second storage device; (b) intercepting arequest for a data block stored on said first storage device; (c)determining whether said data block being requested contains a firsttype of data; (d) upon a condition in which said data block containssaid first type of data, writing said data block to said second storagedevice; (e) upon a condition in which said data block does not containsaid first type of data, determining whether a correspondingly mappedblock on said second storage device contains said first type of data;(f) upon a condition in which said correspondingly mapped block containssaid first type of data aborting the cache write operation; and, (g)upon a condition in which said correspondingly mapped block does notcontain said first type of data, writing said data on said data block tosaid correspondingly mapped block on said second storage device.
 20. Acomputer system according to claim 19, wherein said admission controlmodule further includes instructions for, prior to said writing saiddata: (h) determining whether said correspondingly mapped block containsa second type of data; (i) upon a condition in which saidcorrespondingly mapped block contains said second type of data, abortingthe cache write operation; and, (j) upon a condition in which saidcorrespondingly mapped block does not contain said second type of dataexecuting said writing said data on said data block to saidcorrespondingly mapped block on said second storage device.
 21. Acomputer system according to claim 19, wherein said first type of datais filesystem metadata.
 22. A computer system according to claim 16,wherein said second type of data is data that is more frequentlyaccessed than data on said data block.
 23. A computer system accordingto claim 19, wherein said first storage device is a hard disk drive. 24.A computer system according to claim 19, wherein said second storagedevice is a solid state drive.